Repository navigation
Desktop: Share chat… as a redacted file, secret gist only after a confirm (ATO-581) - #1663
Draft
sosidudku1 wants to merge 2 commits into
Draft
sosidudku1 wants to merge 2 commits into
sosidudku1 wants to merge 2 commits into
Conversation
…confirm (ATO-581)
…d that file For an HTML save the Markdown copy for the gist was written after the Upload answer, so the confirm never named the file that went up and a chat that grew in the meantime could upload more messages than shown. The copy is now written first, the confirm names its path and message count, and exactly that file is uploaded.
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
"Share chat…" in a chat's "…" menu (right under Export…, for a stored chat):
atag share --session <id> --format html|md --out <file> --json(core Share a chat as one redacted file, with an opt-in secret gist (ATO-581) #1445): only your messages and the agent's replies; keys, local paths, emails, IPs and reasoning are removed.gh gist create <file> --desc "Atomic Agent chat: <title>": a secret gist (never--public, pinned by a test), with the person's ownghsign-in. An HTML save uploads a Markdown copy written by the same command, because GitHub shows HTML as source; that copy is written before the confirm, which names its path and message count, and exactly that file goes up. The link is copied and can be opened from the last dialog.New files:
desktop/main/chat-share.ts,desktop/renderer/chat-share.js,desktop/test/chat-share.test.mjs. Hooks: one IPC registration inmain.ts, one preload method (shareSession), one menu item inchat-list.js, one line inrenderer.jsact(), one<script>inindex.html.The bundled core on
rel/xp-buildalready hasatag share(src/cli/share-command.ts, registered insrc/cli/index.ts). An agent without it gets "This agent version cannot share chats. Update Atomic Agent." A window connected to a remote agent is refused in words (the command reads this computer's chat store).Why
ATO-581 / ATO-1504: the core can share a chat, the desktop could not. Core #1445 named the desktop button as not done.
How
Copied ChatGPT / Claude "Share chat" (a look at what goes out, then a link) and Claude Code
/export(a local file first). Unlike them there is no host of ours, so the only way off the machine is the person's own secret gist, asked twice. Same shape as the existing Export… (ATO-1054).Tests
desktop/test/chat-share.test.mjs: the argv toatag share; nothing uploads by default, on the offer alone or on Cancel; the confirm defaults to Cancel; after both yeses the gh argv is a secret gist of the Markdown copy and the link is copied; gh missing / signed out keeps the file and says why; cancel, bad id (an id starting with-is refused), remote agent, old agent; the IPC channel; the menu item.desktop/test/chat-export.test.mjs: menu order updated for the new item.npm run build && npm run test:unitindesktop/is the check.Unverified: the native dialogs by hand, and
ghfound via the app PATH (agentEnv, which appends Homebrew's folder) on a Finder-launched app.Verification
gh gist create. Nothing is regenerated after the yes. Same redaction, same command.chat-share.test.mjsadds a case where every lateratag sharerun would return a new file with more messages; it asserts only two agent runs, the confirm names the first Markdown copy and its count, and gh gets that file. The Markdown save case checks the confirm names the saved file.npm run build && npm run test:unitindesktop/(chat-share tests), and by hand an HTML save, then Create secret gist…: the confirm shows the Markdown path and count, Cancel uploads nothing.Not yet checked on the second Mac.